home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 1994 August / August CD.bin / Shareware / Programming / Infinity Windoid WDEF 2.6 / Makefile < prev    next >
Encoding:
Makefile  |  1994-03-14  |  5.0 KB  |  149 lines  |  [TEXT/MPS ]

  1. # ==============================================================================
  2. #
  3. #    Infinity Windoid 2.6
  4. #
  5. #                makefile for MPW
  6. #
  7. # ------------------------------------------------------------------------------
  8. #              © 1991-94 Troy Gaul
  9. #                Infinity Systems
  10. #                All Rights Reserved
  11. # ------------------------------------------------------------------------------
  12. #   File:       Makefile
  13. #   Target:     Infinity Windoid 2.6
  14. #   Sources:    InfinityWindoid.c
  15. #               WindoidUtil.c
  16. # ==============================================================================
  17.  
  18. Output        =    Infinity Windoid 2.6
  19. PPCOut        =    Infinity Windoid/Fat
  20.  
  21. OutRsrc        =    InfinityWDEF.rsrc            # intermediate file for Fat build
  22.  
  23. # ==============================================================================
  24. #    Types and IDs
  25. # ------------------------------------------------------------------------------
  26.  
  27. Type        =    rsrc
  28. Creator        =    RSED
  29. ResType        =    WDEF
  30. ResID        =    128
  31.  
  32. # ==============================================================================
  33. #    Directories
  34. # ------------------------------------------------------------------------------
  35.  
  36. ObjDir        =    :obj:
  37.  
  38. {ObjDir}    ƒ    :                # directory dependency
  39.  
  40. # ==============================================================================
  41. #    68K Options
  42. # ------------------------------------------------------------------------------
  43.  
  44. COptions    = # -r                # warnings                                     ∂
  45.                 -b                # PC-relative strings                        ∂
  46.                 -mbg off         # off, full                                    ∂
  47.                 -opt full        # off, (empty)=normal, full, size, speed    ∂
  48.                 -o "{ObjDir}"
  49.  
  50. # ==============================================================================
  51. #    PowerPC Options/Libs
  52. # ------------------------------------------------------------------------------
  53.  
  54. PPCCOptions    =    -w conformance -appleext on
  55.  
  56. PPCPefLibs    =    -l InterfaceLib.xcoff=InterfaceLib                            ∂
  57.                 -l StdCLib.xcoff=StdCLib                                    ∂
  58.                 -l MathLib.xcoff=MathLib
  59.  
  60. PPCObjects    =    "{ObjDir}"InfinityWindoid.o                                    ∂
  61.                 "{ObjDir}"WindoidUtil.o
  62.  
  63. PPCLinkLibs    =    "{PPCLibraries}"InterfaceLib.xcoff                             ∂
  64.                 "{PPCLibraries}"StdCLib.xcoff                                 ∂
  65.                 "{PPCLibraries}"StdCRuntime.o                                 ∂
  66.                 "{PPCLibraries}"PPCCRuntime.o
  67.  
  68. # ==============================================================================
  69. #    68K Compilation
  70. # ------------------------------------------------------------------------------
  71.  
  72. "{ObjDir}"InfinityWindoid.c.o    ƒ    Makefile                                 ∂
  73.                                     InfinityWindoid.c    WindoidDefines.h    ∂
  74.                                     WindoidTypes.h        WindoidUtil.h
  75.     C {COptions} InfinityWindoid.c
  76.  
  77. # ------------------------------------------------------------------------------
  78.  
  79. "{ObjDir}"WindoidUtil.c.o        ƒ    Makefile                                 ∂
  80.                                     WindoidUtil.c        WindoidDefines.h    ∂
  81.                                     WindoidTypes.h        WindoidUtil.h
  82.     C {COptions} WindoidUtil.c
  83.  
  84. # ==============================================================================
  85. #    PowerPC Compilation
  86. # ------------------------------------------------------------------------------
  87.  
  88. "{ObjDir}"InfinityWindoid.o        ƒ    Makefile                                 ∂
  89.                                     InfinityWindoid.c    WindoidDefines.h    ∂
  90.                                     WindoidTypes.h        WindoidUtil.h
  91.     PPCC {PPCCOptions} InfinityWindoid.c    -o "{ObjDir}"InfinityWindoid.o
  92.  
  93. # ------------------------------------------------------------------------------
  94.  
  95. "{ObjDir}"WindoidUtil.o            ƒ    Makefile                                 ∂
  96.                                     WindoidUtil.c        WindoidDefines.h    ∂
  97.                                     WindoidTypes.h        WindoidUtil.h
  98.     PPCC {PPCCOptions} WindoidUtil.c        -o "{ObjDir}"WindoidUtil.o
  99.  
  100. # ==============================================================================
  101. #    Object Files
  102. # ------------------------------------------------------------------------------
  103.  
  104. Objects        =    "{ObjDir}"InfinityWindoid.c.o                                ∂
  105.                 "{ObjDir}"WindoidUtil.c.o
  106.  
  107. # ==============================================================================
  108. #    Linking
  109. # ------------------------------------------------------------------------------
  110.  
  111. LinkOpts    =    -m MAIN ∂
  112.                 -sg "{Output}"
  113.  
  114. # ------------------------------------------------------------------------------
  115. #    68K version
  116.  
  117. "{Output}"    ƒƒ    Makefile {Objects}
  118.     Link        -t {Type} -c {Creator} -rt {ResType}={ResID}                ∂
  119.                 {Objects} {LinkOpts}                                        ∂
  120.                 -o {Targ}
  121.  
  122. # ------------------------------------------------------------------------------
  123. #    Fat version - 68K
  124.  
  125. "{OutRsrc}"    ƒƒ    Makefile {Objects}
  126.     Link        -t rsrc -c RSED -rt oCod={ResID}                            ∂
  127.                 {Objects} {LinkOpts}                                         ∂
  128.                 -o {Targ}
  129.  
  130. # ------------------------------------------------------------------------------
  131. #    Fat version - PowerPC
  132.  
  133. "{OutRsrc}"    ƒƒ    Makefile {PPCObjects}
  134.     PPCLink -warn -main main                                                 ∂
  135.             {PPCObjects} {PPCLinkLibs}                                        ∂
  136.             -o "{ObjDir}"InfinityWDEF.xcoff
  137.     makepef -b "{ObjDir}"InfinityWDEF.xcoff -o InfinityWDEF.pef {PPCPefLibs}
  138.     echo "read ∂'pCod∂' (128) ∂"InfinityWDEF.pef∂";" | rez -a -o "{OutRsrc}"
  139.  
  140. # ------------------------------------------------------------------------------
  141. #    Put the versions together in a fat binary WDEF
  142.  
  143. "{PPCOut}"    ƒ    Makefile {OutRsrc}
  144.     rez InfinityWDEF.r -a -o {Targ}
  145.     setfile -t {Type} -c {Creator} {Targ}
  146. #    Delete "{OutRsrc}"        # you might want to delete the intermediate file
  147.  
  148. # ------------------------------------------------------------------------------
  149.